package com.zbkj.front.controller.user;

import com.zbkj.common.annotation.LogControllerAnnotation;
import com.zbkj.common.enums.MethodType;
import com.zbkj.common.model.merchant.MerchantCategory;
import com.zbkj.common.page.CommonPage;
import com.zbkj.common.request.CommonBatchRequest;
import com.zbkj.common.request.MerchantGeneralTypeSaveRequest;
import com.zbkj.common.request.MerchantGeneralTypeSearchRequest;
import com.zbkj.common.request.PageParamRequest;
import com.zbkj.common.response.MerchantGeneralTypeDetailResponse;
import com.zbkj.common.response.MerchantGeneralTypeFrontListResponse;
import com.zbkj.common.response.MerchantGeneralTypeListResponse;
import com.zbkj.common.response.MerchantGeneralTypePageDataResponse;
import com.zbkj.common.result.CommonResult;
import com.zbkj.service.service.MerchantGeneralTypeService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.security.access.prepost.PreAuthorize;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.*;

import java.util.List;

/**
 * 商户联盟类型控制器 前端控制器
 */
@Slf4j
@RestController
@RequestMapping("api/front/merchant/general/type")
@Api(tags = "商户联盟类型控制器") //配合swagger使用

public class MerchantGeneralTypeController {

    @Autowired
    private MerchantGeneralTypeService merchantGeneralTypeService;


    @ApiOperation(value="获取全部分类列表")
    @RequestMapping(value = "/all/list", method = RequestMethod.GET)
    public CommonResult<List<MerchantGeneralTypeFrontListResponse>> allList() {
        return CommonResult.success(merchantGeneralTypeService.allListH5());
    }
}



